package com.jzy.stock.util;

public enum StatusEnum2 {
    QIYONG(1,"启用"),JINYONG(0,"禁用"),QUANBU(3,"全部");

    private String statusName;
    private Integer status;

    StatusEnum2(Integer status, String statusName){
        this.status = status;
        this.statusName = statusName;
    }

    public String getStatusName() {
        return statusName;
    }
    public Integer getStatus() {
        return status;
    }

    public static String queryNameByStatus(Integer status){
        for (StatusEnum2 statusEnum: StatusEnum2.values()){
            if (status==statusEnum.getStatus()){
                return statusEnum.getStatusName();
            }
        }
        return null;
    }

}
